<?PHP	
	if($_GET['mode'] == '')							// MODE: FIRST VISIT
	{
		goto_url('./index.php?mode=Home');
	}
	

	if($_GET['mode'] == 'Home')						// MODE: HOME
	{
?>
<IMG src="./images/home.png" width=800>
<?PHP
	}
	else if($_GET['mode'] == 'Manual')				// MODE: MANUAL
	{
		include('manual.php');
	}
	else if($_GET['mode'] == 'Join')				// MODE: JOIN
	{
		include('./join.php');
	}
	else											// MODE: NOT LOGGED IN
	{
		if(!$_SESSION['user_idx'])
		{
			goto_url('./index.php?mode=Home');
		}
	}
	
	
	if($_SESSION['user_idx'])
	{
		if($_GET['mode'] == 'Experiments')			// MODE: EXPERIMENTS
		{
			include('experiments.php');
		}
		else if($_GET['mode'] == 'Experiment')
		{
			include('experiment.php');
		}
		else if($_GET['mode'] == 'Session')
		{
			include('session.php');
		}
		else if($_GET['mode'] == 'Results')
		{
			include('results.php');
		}
		else if($_GET['mode'] == 'MyAccount')
		{
			include('my_account.php');
		}
		else if($_GET['mode'] == 'Result_asyn')
		{
			include('result_asynPair.php');
		}
		else if($_GET['mode'] == 'Result_nextImage')
		{
			include('result_nextImage.php');
		}
		else if($_GET['mode'] == 'Result_nextText')
		{
			include('result_nextText.php');
		}
	}
?>
